#include<stdio.h>

int find(int a,int b)
{
	if(a%b==0)
		return b;
	else
		return find(b,a%b);
}

int main()
{
	int a=40,b=88;
	printf("%d",find(a,b));
	return 0;
}
